import 'package:json_annotation/json_annotation.dart';

part 'currency_model.g.dart';


@JsonSerializable()
class CurrencyModel extends Object {

  List<Item> item;

  int errcode;

  String message;

  CurrencyModel(this.item,this.errcode,this.message,);

  factory CurrencyModel.fromJson(Map<String, dynamic> srcJson) => _$CurrencyModelFromJson(srcJson);

  Map<String, dynamic> toJson() => _$CurrencyModelToJson(this);

}


@JsonSerializable()
class Item extends Object {

  int id;

  String name;

  String symbol;

  int is_default;

  String rate;

  Item(this.id,this.name,this.symbol,this.is_default,this.rate,);

  factory Item.fromJson(Map<String, dynamic> srcJson) => _$ItemFromJson(srcJson);

  Map<String, dynamic> toJson() => _$ItemToJson(this);

}


